using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Collections.Generic;

public partial class Layer_TileSet : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        /// This Tile Set example was adapted directly from the one given in the MS Virtual Earth Map Control SDK
        /// 

        List<PietschSoft.VE.LatLongRectangle> b = new List<PietschSoft.VE.LatLongRectangle>();
        b.Add(new PietschSoft.VE.LatLongRectangle(new PietschSoft.VE.LatLong(49, -123), new PietschSoft.VE.LatLong(47, -121)));

        PietschSoft.VE.TileSourceSpecification tss = new PietschSoft.VE.TileSourceSpecification();
        tss.Id = "lidar";
        tss.TileSource = "http://dev.live.com/virtualearth/sdk/layers/lidar/%4.png";
        tss.Bounds = b;
        tss.MinZoom = 10;
        tss.MaxZoom = 18;
        Map1.TileSources.Add(tss);

        PietschSoft.VE.LayerSpecification ls = new PietschSoft.VE.LayerSpecification();
        ls.Type = PietschSoft.VE.LayerType.TileSource;
        ls.Id = "1";
        ls.LayerSource = "lidar";
        ls.ZIndex = 100;
        ls.Opacity = 0.5;
        Map1.Layers.Add(ls);
    }
}
